package com.fzkj.thread.demo10;

public class ThreadTest {
    public static void main(String[] args) {
        // 创建线程对象
        Thread t = new Thread(new DownLoad("第一个线程"));
        Thread t1 = new Thread(new DownLoad("第二个线程"));
        Thread t2 = new Thread(new DownLoad("第三个线程"));
        // 加入线程
        t.start();
        try { // start和join的顺序不能变
            t.join();
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        t1.start();
        t2.start();

    }
}
